// Only for devs.


#ifndef LIGHTY_DEBUG_H
#define LIGHTY_DEBUG_H

#include <iostream>
#include <fstream>
#include <ctime>

bool debugprinting=true;
bool debuglogs=true;

void Lighty_PrintDebug(const char* msg){
	
  time_t tmNow;
  tmNow = time(NULL);
  struct tm t=*localtime(&tmNow);

  if(debugprinting){
    
    std::cerr<<msg<<" | "<<t.tm_hour<<":"<<t.tm_min<<":"<<t.tm_sec<<"\n";
      
  }
    
  if(debuglogs){
	
    std::ofstream file;
    file.open("log.txt", std::ios::app);
    file<<msg<<" | "<<t.tm_hour<<":"<<t.tm_min<<":"<<t.tm_sec<<"\n";
    file.close();
    
  }

}

#endif
